//  获取路径中的文件扩展名

const path = require('path')

const fpath = '/a/b/c/index.html' //假设为文件存放的路径

const fullName = path.extname(fpath);
console.log(fullName);